package com.zoe.onelink.business.dao;

import com.zoe.onelink.business.cache.bean.ParamEntity;
import com.zoe.onelink.business.cache.bean.SysParam;
import com.zoe.onelink.business.cache.bean.SysParamCustom;
import org.apache.ibatis.annotations.Param;

/**
 * <p>标题: </p>
 * <p>描述: </p>
 * <p>版权: Copyright (c) 2019</p>
 * <p>公司: 智业软件</p>
 *
 * @version: 1.0
 * @author: lanzhe
 * @date: 2019/11/25
 */
public interface ParamDao {

    /**
     * 获取定制参数
     */
    ParamEntity getCustomParam(@Param("customParamClassName") String customParamClassName, @Param("customParamClassValue") String customParamClassValue,
                               @Param("paramName") String paramName);

    /**
     * 获取系统参数
     *
     * @param paramEnglishName 参数名
     */
    ParamEntity getGlobalParam(@Param("paramEnglishName") String paramEnglishName);

    /**
     * 获取业务参数 (定制参数+系统参数)
     * @param paramName
     * @param operator
     * @param deptCode
     * @param districtCode
     * @return
     */
    ParamEntity getBizParam(String paramName, String operator, String deptCode, String districtCode);

    /**
     * 插入全局参数
     */
    int insertGlobalParam(@Param("params") SysParam sysParam);

    /**
     * 插入定制参数
     */
    int insertCustomParam(@Param("params") SysParamCustom sysParamCustom);

}
